package com.clw.classpath;

import com.clw.utils.FileUtil;
import java.io.IOException;

/**
 * Created by chengliwei on 2018/12/17.
 */
public class ClassEntry implements Entry {

    private String classPath;

    public ClassEntry(String classPath) {
        this.classPath = classPath;
    }

    @Override
    public byte[] readClass(String className) throws IOException {
        return classPath.contains(className) ? FileUtil.read(classPath) : null;
    }
}
